package cn.tianjindong.blog_portal.controller;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import cn.tianjindong.blog.pojo.BlogLink;
import cn.tianjindong.blog_portal.service.LinkService;

/**
 * 标签相关Controller
 * @author 田 金 东
 *
 */
@Controller
public class LinkController {
	
	@Autowired
	private LinkService linkService;
	
	@RequestMapping("/links.html")
	public String toLinkPage(Model model){
		List<BlogLink> list = linkService.getLinkList();
		model.addAttribute("list", list);
		return "/links";
	}
	
}
